<?php
namespace app\common\validate;

use think\Validate;

class ResumeEducationValidate extends Validate
{
    protected $rule =   [
        'resume_id|简历ID'    => 'require|number',
        'school|学校名称'     => 'require|length:1,100',
        'speciality|专业'     => 'require|length:1,20',
        'education|学历'      => 'require|number',
        'start_time|入学时间' => 'require|date',
        'end_time|毕业时间'   => 'require|date',
    ];
    
    protected $scene = [
        /** api */
        'add'    => ['resume_id', 'school', 'speciality', 'education', 'start_time', 'end_time'],
    ];
}